package br.com.krk;

import br.com.carcara.krk.R;
import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class Act_Sincronizar extends Activity implements OnClickListener {
	
	Button btnImport, btnExport, btnConfigWS, btnVoltar;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.tela_sincronizar);
		
		InicializaObjetos();
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.tela_sincronizar, menu);
		return true;
	}

	@Override
	public void onClick(View v) {
		if (v == btnConfigWS) {
			Intent i = new Intent(this, Act_ConfigWS.class);
			startActivity(i);
		}else if (v == btnExport) {
			
		}else if (v == btnImport) {
			
		}else if (v == btnVoltar) {
			finish();
		}
		
	}
	
	public void InicializaObjetos() {
		btnConfigWS = (Button) findViewById(R.telaSincrozinar.btnConfigWS);
		btnExport   = (Button) findViewById(R.telaSincrozinar.btnExportarXML);
		btnImport   = (Button) findViewById(R.telaSincrozinar.btnImportarXmls);
		btnVoltar   = (Button) findViewById(R.telaSincrozinar.btnVoltar);
		btnConfigWS.setOnClickListener(this);
		btnExport.setOnClickListener(this);
		btnImport.setOnClickListener(this);
		btnVoltar.setOnClickListener(this);
	}

}
